package com.assignwork.service;

import com.assignwork.dto.ShiftRuleTimeSpaceSubmitDTO;
import com.assignwork.entity.ShiftRuleTimeSpace;
import com.assignwork.vo.ShiftRuleTimeSpaceVO;
import org.springblade.core.mp.base.BaseService;

import java.util.List;

/**
 * @ClassName IShiftRuleTimeSpaceService
 * @Description 班组生成规则时间段信息
 * @Author dujianyu
 * @Date 2023/12/1 16:08
 */
public interface IShiftRuleTimeSpaceService extends BaseService<ShiftRuleTimeSpace> {

    /**
     * 根据规则Id删除时间段信息
     * @param ruleId 规则ID
     * @return boolean
     * @author dujianyu
     * @since 2023/12/4 9:05
     */
    boolean removeSRTimeSpacesByRuId(Long ruleId);

    /**
     * 批量新增
     * @param timeSpaces 数据数组
     * @return boolean
     * @author dujianyu
     * @since 2023/12/4 9:21
     */
    boolean submitSRTimeSpaceBatch(List<ShiftRuleTimeSpaceSubmitDTO> timeSpaces);

    /**
     * 根据规则ID返回时间段信息
     * @param ruleId 规则ID
     * @return List<ShiftRuleTimeSpaceVO>
     * @author dujianyu
     * @since 2023/12/5 10:43
     */
    List<ShiftRuleTimeSpaceVO> selectSRTimeSpaceListByRuleId(String ruleId);

}
